package Test4;

public class Test {
    public static void main(String[] args) {
        Comparable comparable=new CompareStudent();
        Student student=new Student(comparable,123,"小王",18,80);
        Student student2=new Student(comparable,154,"小李",18,90);
        System.out.println(student.compareToStu(student2));
        comparable=new CompareNews();
        News news=new News(comparable,123,"hh","什么",150);
        News news2=new News(comparable,158,"jj","什么",100);
        System.out.println(news.compareToNews(news2));
    }
}
